package com.smartgame.renderers;

import com.badlogic.gdx.Gdx;
import com.smartgame.controllers.AbstractController;
import com.smartgame.util.Assets;
import com.smartgame.util.Constants;

public class MenuRenderer extends AbstractRenderer {

	public MenuRenderer(AbstractController controller) {
		super(controller);
	}
	
	@Override
	public void renderWorld() {
		super.renderWorld();
		Assets.instance.fonts.defaultBig.draw(
				batch, "Click me to start game!", 
				Gdx.graphics.getWidth() / 2 - 100, Gdx.graphics.getHeight() / 2);
	}

	@Override
	protected void updateBatchWithCamera() {
		batch.setProjectionMatrix(guiCamera.combined);
	}
	
	@Override
	public void resize(int width, int height) {
		guiCamera.viewportWidth = (Constants.VIEWPORT_GUI_WIDTH / height) * width;
		guiCamera.update();
	}

}
